package com.example.demo.entity;

import lombok.Data;

import java.io.Serializable;

//import javax.persistence.Entity;
//import javax.validation.constraints.NotNull;
//
//import org.hibernate.validator.constraints.NotBlank;
//import org.hibernate.validator.constraints.NotEmpty;
//
//import com.fasterxml.jackson.annotation.JsonIgnore;

//@Entity
@Data
public class User implements Serializable {
    /**
     *
     */
    private static final long serialVersionUID = 1L;
    //@JsonIgnore
//    @NotNull(message="Id不能为空")
    private int Id;
    //@JsonIgnore
    private String name;

    //@JsonIgnore
//    @NotBlank(message="密码不能为空")
    private String password;
    //@NotNull(message="age不能为空")
    private int age;

    public User( ) {

    }
    public User(int id, String name, String password, int age) {
        Id = id;
        this.name = name;
        this.password = password;
        this.age = age;
    }
}